package org.example.StacksAndQueues;

public class Using_Stacks_to_Implement_Queues {
    public static void main(String[] args) {
        //用栈实现队列

        //测试类
        MyQueue myQueue = new MyQueue();
        myQueue.push(1);
        myQueue.push(2);
        myQueue.push(3);
        myQueue.push(4);
        myQueue.push(5);
        System.out.println(myQueue.pop());
        System.out.println(myQueue.peek());
        System.out.println(myQueue.pop());
        System.out.println(myQueue.empty());
    }

}
